using System;
using System.Data;
using System.Collections.Generic;
using System.Text;
using BA.DAL;

namespace BlazeApps.Library.News
{
    public class NewsList : Base
    {
        private BA.DAL.DBUtility DAL = new BA.DAL.DBUtility();
        private Procedures Procs = new Procedures();

        public DataTable GetNews()
        {
            DAL.CreateDBObjects(ConnectionString, Provider);

            return DAL.GetDataTable(Procs.ListNews.ToString().Trim(), System.Data.CommandType.Text, System.Data.ConnectionState.Open);
        }

		public DataTable GetNewsArchive()
		{
			DAL.CreateDBObjects(ConnectionString, Provider);

			return DAL.GetDataTable(Procs.ListNewsArchive.ToString().Trim(), System.Data.CommandType.Text, System.Data.ConnectionState.Open);
		}
    }
}
